package com.xbongbong.parent.interfaces;

import com.alibaba.fastjson.JSONObject;
import com.xbongbong.paas.field.FieldAttrEntity;
import com.xbongbong.paas.pojo.FormTitlePoJo;
import com.xbongbong.paas.pojo.SummaryDataPoJo;
import com.xbongbong.paas.toolbox.exception.XbbException;
import com.xbongbong.pro.formdata.pojo.dto.FormDataDetailDTO;
import com.xbongbong.pro.formdata.pojo.vo.FormDataDetailVO;
import com.xbongbong.pro.formdata.pojo.vo.MobileFormCommonDetailVO;

import java.util.List;
import java.util.Map;

/**
 * 返回tab栏上班部分数据
 * @author 吴峰
 * @date 2021/12/22 20:52
 */
public interface BusinessDetailTopInfoService<T, D> extends ParentBusinessDetailService<T, D>, BusinessWebDetailTopInfoService<T, D>, BusinessMobileDetailTopInfoService<T, D> {

    /**
     * 手机端，获取详情的头部信息
     * @param formDataGetDTO
     * @return
     * @throws XbbException
     */
    MobileFormCommonDetailVO getMobileDetail(FormDataDetailDTO formDataGetDTO) throws XbbException;
    /**
     * 获取详情的头部信息
     * @param formDataDetailDTO
     * @return
     * @throws XbbException
     */
    FormDataDetailVO getDetail(FormDataDetailDTO formDataDetailDTO) throws XbbException;



    /**
     * 获取表单
     * @param formDataDetailDTO
     * @param form
     * @param corpid
     * @return
     * @throws XbbException
     */
    T getForm(FormDataDetailDTO formDataDetailDTO, D form, String corpid) throws XbbException;


    /**
     * 获取摘要
     * com.xbongbong.saas.help.ProDetailHandlerHelp#handelDetail(java.lang.Integer, java.lang.Long, com.alibaba.fastjson.JSONObject, java.lang.Integer, java.util.Map, com.xbongbong.paas.domain.entity.ext.PaasFormDataEntityExt, java.lang.String, java.lang.Long, com.alibaba.fastjson.JSONArray, com.alibaba.fastjson.JSONArray, com.xbongbong.paas.domain.entity.ext.PaasFormEntityExt, java.util.List, com.xbongbong.paas.pojo.DetailTitlePojo, java.lang.Integer, java.lang.String) 2184行
     * @param formData
     * @param formDataDetailDTO
     * @param formEntity
     * @param list
     * @param data
     * @return
     * @throws XbbException
     */
    List<SummaryDataPoJo> getSummaryList(FormDataDetailDTO formDataDetailDTO, D formData, T formEntity, List<FieldAttrEntity> list, Map<String, FieldAttrEntity> explainMap, JSONObject data) throws XbbException;


    /**
     * 获取标签
     * com.xbongbong.saas.help.ProDetailHandlerHelp#handelDetail(java.lang.Integer, java.lang.Long, com.alibaba.fastjson.JSONObject, java.lang.Integer, java.util.Map, com.xbongbong.paas.domain.entity.ext.PaasFormDataEntityExt, java.lang.String, java.lang.Long, com.alibaba.fastjson.JSONArray, com.alibaba.fastjson.JSONArray, com.xbongbong.paas.domain.entity.ext.PaasFormEntityExt, java.util.List, com.xbongbong.paas.pojo.DetailTitlePojo, java.lang.Integer, java.lang.String) 2184行
     * @param formData
     * @param formDataDetailDTO
     * @param formEntity
     * @param list
     * @param data
     * @return
     * @throws XbbException
     */
    List<SummaryDataPoJo> getLabelList(FormDataDetailDTO formDataDetailDTO, D formData, T formEntity, List<FieldAttrEntity> list, Map<String, FieldAttrEntity> explainMap, JSONObject data) throws XbbException;


    /**
     * 获取标题
     * @param formData
     * @param formDataDetailDTO
     * @param formEntity
     * @param list
     * @param data
     * @return
     * @throws XbbException
     */
    List<FormTitlePoJo> getTitleList(FormDataDetailDTO formDataDetailDTO, D formData, T formEntity, List<FieldAttrEntity> list, Map<String, FieldAttrEntity> explainMap, JSONObject data) throws XbbException;

}
